package com.sjm.bookshop.dao;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.sjm.bookshop.entity.Book;
import com.sjm.bookshop.entity.BookS;
import com.sjm.bookshop.entity.Cart;
import com.sjm.bookshop.entity.UCart;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

@Mapper
public interface CartMapper extends BaseMapper<Cart> {

    int update(Cart cart);
    List<UCart> getCartByUserId(@Param("u_id") int u_id);

    /**
     * 批量删除
      * @param list
     * @return
     */
    int deleteBatchById(@Param("list") List<Integer> list);
}
